package com.scfire.project

import org.grails.databinding.BindingFormat

class Payment implements Comparable {
	//支付订单
	String oa
	//剥离外键
	int project
	
	//打款金额
	int payMoney
	
	//操作者
	int member
	
	//备注
	String remark
	
	
	
	//创建时间
	@BindingFormat('yyyy-MM-dd HH:mm')
	Date date

    static constraints = {
		oa  nullable:false
		project nullable:false
		payMoney nullable:true
		member nullable:true
		date nullable:true
		remark nullable:true
    }
	@Override
	public int compareTo(Object o) {
		try{
			date.compareTo(o?.date)
		}catch(Exception e){
			return 1
		}
	}
}
